import React from 'react';
import { storiesOf } from '@kadira/storybook';
import { withKnobs, number } from '@kadira/storybook-addon-knobs';
import { muiTheme } from 'storybook-addon-material-ui';
import RiskSlider from './RiskSlider';
/*global module*/

storiesOf('リスク スライダ', module)
  .addDecorator(muiTheme())
  .addDecorator(withKnobs)
  .add('男性', () => (
    <RiskSlider
      gender="male"
      current={number('current', 29.152)}
      initial={number('initial', 20.125)}
      min={number('min', 11.852)}
      max={number('max', 30.425)}
      decimalDigit={number('decimalDigit', 1)}
    />
  ))
  .add('女性', () => (
    <RiskSlider
      gender="female"
      current={number('current', 29.152)}
      initial={number('initial', 20.125)}
      min={number('min', 11.852)}
      max={number('max', 30.425)}
      decimalDigit={number('decimalDigit', 1)}
    />
  ))
  .add('初期状態と現在値が同じ', () => (
    <RiskSlider
      gender="male"
      current={number('current', 29.152)}
      initial={number('initial', 29.125)}
      min={number('min', 11.852)}
      max={number('max', 30.425)}
      decimalDigit={number('decimalDigit', 1)}
    />
  ))
  .add('最低値', () => (
    <RiskSlider
      gender="male"
      current={number('current', 11.852)}
      initial={number('initial', 29.125)}
      min={number('min', 11.852)}
      max={number('max', 30.425)}
      decimalDigit={number('decimalDigit', 1)}
    />
  ))
  .add('最高値', () => (
    <RiskSlider
      gender="male"
      current={number('current', 30.452)}
      initial={number('initial', 29.125)}
      min={number('min', 11.852)}
      max={number('max', 30.425)}
      decimalDigit={number('decimalDigit', 1)}
    />
  ));
